package gxprod.androidai.support;

import gxprod.androidai.PopupAIActivity;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.util.Log;
import android.widget.Toast;

public class SpeekReceiver extends BroadcastReceiver {

	public static final int HELLO_ID = 1;

	@Override
	public void onReceive(Context context, Intent intent) {
		Intent i = new Intent(context, PopupAIActivity.class);
		i.fillIn(intent, Intent.FILL_IN_DATA);
		i.setFlags(i.getFlags() | Intent.FLAG_ACTIVITY_NEW_TASK);
		context.startActivity(intent);
		Toast.makeText(context, intent.getStringExtra("title"), Toast.LENGTH_LONG);
		Log.i("SpeekReciever", "SpeekReciver sucessfully invoked");		
	}
};